package com.tian.mapper;

import com.tian.pojo.User;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import com.tian.pojo.Patients;
import java.util.List;

@Mapper
public interface PatientsMapper {
        @Select("select * from patients")
        List<Patients> findAll();

        @Select("select name from patients")
        List<Patients> findName();

        @Insert({"insert into patients(id,name,sex,age) values(#{id},#{name},#{sex},#{age})"})
        void insert(Patients patients);

        @Select("select * from user")
        List<User> findUser();

}
